package com.example.tpintegrador;

import android.content.Context;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import android.widget.ArrayAdapter;
import android.widget.TextView;

public class RegistroServWebArrayAdapter extends ArrayAdapter{
	private final Context context;
	private final String[] values;
	private final String[] values2;
 
	public RegistroServWebArrayAdapter(Context context, String[] values, String[] values2) {
		super(context, R.layout.registro_serv_web_item, values);
		this.context = context;
		this.values = values;
		this.values2=values2;
	}
	
	@Override
	public View getView(int position, View convertView, ViewGroup parent) {
		LayoutInflater inflater = (LayoutInflater) context
			.getSystemService(Context.LAYOUT_INFLATER_SERVICE);
 
		View rowView = inflater.inflate(R.layout.registro_serv_web_item, parent, false);
		TextView textView = (TextView) rowView.findViewById(R.id.txtFecha);
		TextView textView2 = (TextView) rowView.findViewById(R.id.txtMensaje);
		textView.setText(values[position]);
		textView2.setText(values2[position]);
 
		String s = values[position];
		String s2 = values2[position];
 
		System.out.println(s);
		System.out.println(s2);
		
		return rowView;
	}
}
